package com.sun.web.listener;

import org.apache.shiro.session.Session;
import org.apache.shiro.session.SessionListener;
import org.springframework.stereotype.Component;

/**
 * Created by pullFoot_youth on 2017/2/22.
 */
@Component
public class MySessionListener implements SessionListener {
    @Override
    public void onStart(Session session) {
        System.out.println("session 创建--sessionID : "+ session.getId());
    }

    @Override
    public void onStop(Session session) {
        System.out.println("session 停止--sessionID : "+ session.getId());

    }

    @Override
    public void onExpiration(Session session) {
        System.out.println("session 过期--sessionID : "+ session.getId());

    }
}
